;; The first four lines of this file were added by Dracula.
;; They tell DrScheme that this is a Dracula Modular ACL2 program.
;; Leave these lines unchanged so that DrScheme can properly load this file.
#reader(planet "reader.rkt" ("cce" "dracula.plt") "modular" "lang")
; Usage Instructions
; (stock-market-analysis data-file query-file output-file)  
;     --generates output file based on queries and data
;     data-file is a string naming a text file
;     query-file is a string naming a text file
;     output-file is a string naming a text file

; The stock-market-analysis function reads in a text file
; with queries in it and a text file with stock market data
; in it, it also accepts a text file to write its results to.
; Data is of form YYYYMMDD, TickerName, OpeningPrice, HighestPrice, 
;     LowestPrice, ClosingPrice, NumberSharesTraded
; Queries can be Volume, Volatility, Performance, Avergae Performance
;     Queries are of form nameofquery|startdate|enddate|listoftickers

; Example invocations
; (stock-market-analysis "data.txt" "queries.txt" "output.txt") --writes file: output.txt

(require "Mstockhelper.lisp")
(require "Mperformance.lisp")
(require "Mvolatility.lisp")
(require "Mvolume.lisp")
(require "Mavgperformance.lisp")
(require "Mcodec.lisp")

(link Rcodec
  (import)        ; no imports
  (export Icodec) ; specifies names visible in Rcodec
  (Mstockhelper Mperformance Mvolatility Mvolume Mavgperformance Mcodec))

(invoke Rcodec)
